package com.coffee.admin.service.platform.dao;

import com.coffee.admin.api.platform.query.PlatformQuery;
import com.coffee.admin.api.platform.rep.PlatformOperateRes;
import com.coffee.admin.service.platform.bean.Platform;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface PlatformDao {
	public Platform findById(Integer id);
	
	public Platform findByIdForUpdate(Integer id);
	
	public List<Platform> findByIds(@Param("idList") List<Integer> idList);

	public Integer count(@Param("param") PlatformQuery param);

	public List<Platform> page(@Param("param") PlatformQuery param, @Param("offset") Integer offset, @Param("rows") Integer rows);

	public Platform findFirst(@Param("param") PlatformQuery param);

	public Integer insert(Platform param);

	Integer insertBatch(List<Platform> list);

	public void updateById(@Param("param") Platform param);
	
	public Integer deleteById(Integer id);
	
	public Integer deleteByIds(List<Integer> idList);


	public List<PlatformOperateRes> pageByPlatformOperateRes(@Param("param") PlatformQuery param, @Param("offset") Integer offset, @Param("rows") Integer rows);

	PlatformOperateRes findMerchantOperatorDetail(@Param("param") PlatformQuery param);
}